package com.wx.wxpush.mapper;

import com.wx.wxpush.entiy.TempData;
import com.wx.wxpush.entiy.TemplateData;
import com.wx.wxpush.entiy.UserInfo;
import org.apache.ibatis.annotations.Select;
import org.springframework.stereotype.Component;

import java.sql.ResultSet;
import java.util.List;

@Component
public interface UserInfoMapper {
    int insertUser(UserInfo userInfo);

    List<UserInfo> selectAll();

    UserInfo selectByNick(String nickname);

    String selectByopenid(String openid1);

    @Select("select  so.morning_template_id as morningTemplateId,so.eve_template_id as eveTemplateId," +
            "lianaitime,birthday,remark,so.ipAddress,cronmoring,cornnight,moringStatus,nightStatus,district" +
            "" +
            " from sys_openid so left join cron c on so.openid=c.openid where so.openid=#{openid}")
    TemplateData selectTempList(String openid);

//    List<Object> selectTempList(String openid);

//    @Select("select * from userinfo")
//    List<UserInfo> selectAllPage();
}
